package com.lgm.ht.controller;

import com.lgm.ht.service.BannerService;
import com.lgm.ht.utils.ResultModel;
import com.lgm.ht.vo.BannerVO;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RequiredArgsConstructor
@RestController
@RequestMapping("/banner")
public class BannerController {

    final private BannerService bannerService;


    @GetMapping
    public ResultModel<List<BannerVO>> find(){
        return bannerService.find();
    }
}
